
Ext.define('DCApp.view.payhistory.List', {
    extend: 'Ext.grid.Panel',
    alias: 'widget.payhistorylist',

    requires: [
        'DCApp.view.pay.ListModel',
        'DCApp.controller.ListController'
    ],

    // Connects to our View Controller (Ticket.view.ticket.SearchController) and View Model
    // (Ticket.view.ticket.SearchModel).
    controller: 'list',
    plugins: ['gfilters'],
    viewModel: {
        type: 'payhistorylist'
    },
    header:false,
    selType: 'cellmodel',
    bind: {
        store: '{objs}'
    },

    tbar: ['->',{
        text: '录入',
        handler: 'onNew'
    }],


	listeners: {
        itemdblclick: 'onDblClick'
    },

    columns: [
            {
                text     : '编号',
                dataIndex: 'id'
            },
            {
                text     : '起始日期',
                dataIndex: 'beginTm'
            },
            {
                text     : '结束日期',
                dataIndex: 'endTm'
            },
            {
                text     : '发放人',
				dataIndex: 'confirmMan',
				width:220
            },
            {
                text     : '发放表路径',
                dataIndex: 'path',
                width:300,
                renderer:function(v,r,rec, rowIndex, columnIndex, store){
                	return "<a target='_blank' href='/fileopen?fp=" + v + "'>"+v+"</a>";
                }
            }

        ],
    initComponent: function(){
    	this.callParent();
    }
 });
